package o;

import android.content.SharedPreferences;
import android.content.SharedPreferences.Editor;

public class csr {
    protected static final SharedPreferences ˏ = ContentManager.getInstant().getContext().getSharedPreferences("ProductPurchaseInfo", 0);

    public static long ॱ() {
        return ˋ("repeat_limit_time", 300);
    }

    public static void ˏ(long j) {
        ˏ("repeat_limit_time", j);
    }

    public static boolean ˊ() {
        return ॱ("jump_tips", true);
    }

    public static void ˎ(boolean z) {
        ˋ("jump_tips", z);
    }

    private static void ˏ(String str, long j) {
        try {
            Editor edit = ˏ.edit();
            edit.putLong(str, j);
            edit.apply();
        } catch (Exception e) {
            crf.ˎ.ˊ("ProductPurchaseSP", "putLong error!!key:" + str);
        }
    }

    private static long ˋ(String str, long j) {
        try {
            j = ˏ.getLong(str, j);
        } catch (ClassCastException e) {
            ˏ.edit().remove(str).apply();
        }
        return j;
    }

    private static void ˋ(String str, boolean z) {
        try {
            Editor edit = ˏ.edit();
            edit.putBoolean(str, z);
            edit.apply();
        } catch (Exception e) {
            crf.ˎ.ˊ("ProductPurchaseSP", "putBoolean error!!key:" + str);
        }
    }

    private static boolean ॱ(String str, boolean z) {
        try {
            z = ˏ.getBoolean(str, z);
        } catch (ClassCastException e) {
            ˏ.edit().remove(str).apply();
        }
        return z;
    }
}
